<%@ page language="java" import="com.alibaba.fastjson.JSONObject" pageEncoding="UTF-8" %>
<%@ page import="weaver.conn.RecordSet" %>
<%@ page import="weaver.general.Util" %>
<%--用款流程关联合同流程清单--%>
<%
    String bz = Util.null2String(request.getParameter("bz"));
    JSONObject dataJson = new JSONObject();
    String code = "fail";
    try {
        RecordSet rs = new RecordSet();
        String sql = "select hl from (select (hl/wbsl) as hl from uf_saphlb where wbbb=? and bbbb='CNY' order by sxrq desc) where rownum=1 ";
        rs.executeQuery(sql, bz);
        if (rs.next()) {
            String hl = Util.null2String(rs.getString("hl"));
            dataJson.put("hl", hl);
            code = "success";
        }
        dataJson.put("code", code);
    } catch (Exception e) {
        e.printStackTrace();
    }
    out.print(dataJson.toJSONString());

%>



